<?php
/*
 * @Author       : chaihao
 * @Date         : 2020-06-04 09:56:30
 * @FilePath     : /ai/controllers/api/ApiController.php
 */

namespace app\controllers\api;

use app\commands\Helper;
use yii\web\Controller;



class ApiController extends Controller
{


    public $req = array();
    public $user = array();

    /**
     * 安全 校验 屏蔽
     * 预处理  权限等等操作处理
     */
    public function beforeAction($action)
    {
        $this->req = Helper::in(array_merge($_POST, $_GET));
        $this->user = Helper::checksign($this->req);
        unset($this->req['token']);
        return true;
    }
}
